import { IResponseBase } from '../../user/type'
export interface IResponseSpuList {
  id: string
  createTime: string
  updateTime: string
  spuName: string
  description: string
  category3Id: number | string
  tmId: number | string
  spuSaleAttrList: null
  spuImageList: null
  spuPosterList: null
}
export interface ISpuData {
  category3Id: string
  id?: number
  spuName: string
  tmId: string
  description: string
  spuImageList: any
  spuSaleAttrList: any
}
export interface IResponseSpuData extends IResponseBase {
  data: {
    records: IResponseSpuList[]
    total: number
    size: number
    current: number
    orders: any
    optimizeCountSql: boolean
    hitCount: boolean
    countId: null
    maxLimit: null
    searchCount: boolean
    pages: number
  }
}
//单个品牌类型
export interface ISingleTrademark {
  id: number
  createTime: string
  updateTime: string
  tmName: string
  logoUrl: string
}
//所有品牌数据的ts类型
export interface IResponseTradeMark extends IResponseBase {
  data: ISingleTrademark[]
}
//每个品牌图片的类型
export interface ISingleImg {
  id: number
  createTime: string
  spuId: number
  imgUrl: string
  imgName: string
  updateTime: string
}
//品牌照片墙
export interface IResponseTrademarkImgList extends IResponseBase {
  data: ISingleImg[]
}

export interface IResponseBaseAttrList extends IResponseBase {
  data: { id: number; createTime: string; updateTime: string; name: string }[]
}
export interface ISkuParam {
  category3Id: string
  spuId: string
  tmId: string
  skuName: string
  price: number | number
  weight: string | number
  skuDesc: string
  skuAttrValueList: { attrId: string; valueId: string; [key: string]: any }[]
  skuSaleAttrValueList: {
    saleAttrId: string
    saleAttrValueId: string
    [key: string]: any
  }[]
  skuDefaultImg: string
  [key: string]: any
}

export interface ISkuDataResponse extends IResponseBase {
  data: ISkuParam[]
}
